package com.aerospace.kafka.common.listener;

import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.kafka.annotation.KafkaListeners;
import org.springframework.stereotype.Component;

/**
 * @ClassName KafkaListenerComponet
 * @Description
 * @Author yuhang11
 * @Date 2022/3/31 12:02 下午
 * @Version 1.0
 */
@Component
public class KafkaListenerComponet {
    @KafkaListeners(value = {@KafkaListener(topicPattern = "data_sec_audit_log")})
    public void receiveRecord(ConsumerRecord<String, String> record){
        System.out.println("Find: "+record.value());
    }
}
